<!DOCTYPE html>
<html>
<?php echo $this->fetch('head.html'); ?>
<body>
<div class="fullscreen">
  <div class="scroll_content">
  <div class="topfixed">
    	<div class="t_left"><a href="/index.php?m=koudai_order&a=my"><i class="back"></i></a></div>
      <div class="t_main">超市订单</div>
       
    </div>
    <div class="paddingheight"></div>
    
    
    <div class="comblock">
      <ul class="order_state_step clearfix">
        <li <?php if ($this->_var['data']['status'] == 0): ?>class="cur"<?php endif; ?>>
          <p><span class="dot"></span> </p>
          <p class="txt">待处理</p>
        </li>
        <li <?php if ($this->_var['data']['status'] == 1): ?>class="cur"<?php endif; ?>>
          <p><span class="dot"></span><span class="line"></span> </p>
          <p class="txt">待发货</p>
        </li>
        
        <li <?php if ($this->_var['data']['status'] == 2): ?>class="cur"<?php endif; ?>>
          <p><span class="dot"></span><span class="line"></span> </p>
          <p class="txt">待完成</p>
        </li>
        <li <?php if ($this->_var['data']['status'] == 3): ?>class="cur"<?php endif; ?>>
          <p><span class="dot"></span><span class="line"></span> </p>
          <p class="txt">已完成</p>
        </li>
         
      </ul>
    </div>
    <div class="comblock">
      <div class="order_state_buy">
       
        <p>下单合计：<span class="red"><?php echo count($this->_var['order_product']); ?>件商品，￥<?php echo $this->_var['data']['money']; ?>元 </span></p>
        <?php $_from = $this->_var['order_product']; if (!is_array($_from) && !is_object($_from)) { $_from=array();}; $this->push_vars('', 'p');if (count($_from)):
    foreach ($_from AS $this->_var['p']):
?>
        <p class="spe"><span class="fl"><?php echo $this->_var['p']['title']; ?></span><span class="fr">×<?php if ($this->_var['p']['amount_send']): ?><?php echo $this->_var['p']['amount_send']; ?><?php else: ?><?php echo $this->_var['p']['amount']; ?><?php endif; ?> <span class="red">￥<?php echo $this->_var['p']['order_price']; ?></span></span></p>
        <?php endforeach; endif; unset($_from); ?><?php $this->pop_vars();; ?>
      </div>
    </div>
    <div class="comblock">
      <div class="order_state_info">
        <div class="title">订单信息</div>
        <ul class="list">
          <li></li>
        </ul>
        <ul class="list">
          <li> 订单编号：<?php echo $this->_var['data']['orderno']; ?></li>
          <li>下单时间：<?php echo date("Y-m-d H:i:s",$this->_var['data']['dateline']); ?> </li>
           <li>订单价格：￥<?php echo $this->_var['data']['money']; ?></li>
          <li>商品价格：￥<?php echo $this->_var['data']['goods_money']; ?></li>
          
          <li>优惠券：￥<?php echo $this->_var['data']['coupon_money']; ?></li>
        </ul>
        <ul class="list">
          <li> 联系姓名：<?php echo $this->_var['addr']['truename']; ?></li>
          <li>联系电话：<?php echo $this->_var['addr']['telephone']; ?></li>
          <li>联系地址：<?php echo $this->_var['addr']['p_c_t']; ?> 宿舍：<?php echo $this->_var['addr']['sushe']; ?>  <?php echo $this->_var['addr']['address']; ?></li>
        </ul>
        <ul class="list">
          <li> 订单备注：<?php echo $this->_var['data']['comment']; ?> </li>
        </ul>
         <ul class="list">
          <li> 付款方式：<?php if ($this->_var['data']['unpay']): ?>货到付款<?php else: ?> <?php echo $this->_var['order_ispay'][$this->_var['data']['ispay']]; ?>   <?php if (! $this->_var['data']['unpay'] && $this->_var['data']['ispay'] == 1): ?><a href="/index.php?m=koudai_order&a=pay&order_id=<?php echo $this->_var['data']['order_id']; ?>">去支付</a><?php endif; ?><?php endif; ?> </li>
          <li>订单状态：<?php echo $this->_var['order_status_list'][$this->_var['data']['status']]; ?> 
          <?php if ($this->_var['data']['status'] > 1 && $this->_var['data']['status'] < 4): ?>
           请耐心等待，配送员电话是：<?php echo $this->_var['data']['kdy_telephone']; ?>
          <?php endif; ?>
          
          <?php if ($this->_var['data']['status'] == 2): ?>
          <?php if ($this->_var['data']['isreceived'] == 1): ?>
          <a href="/index.php?m=koudai_order&a=receive&order_id=<?php echo $this->_var['data']['order_id']; ?>">确认收货</a>
          <?php else: ?>
          已收货
          <?php endif; ?>
          <?php endif; ?>
          </li>
        </ul>
    
        <?php if ($this->_var['data']['status'] == 0): ?>
        <a href="/index.php?m=koudai_order&a=cancel&order_id=<?php echo $this->_var['data']['order_id']; ?>" class="cart_change_btn">取消订单</a> <br>
        <?php endif; ?>
        <?php if ($this->_var['data']['status'] == 2): ?>
        <a href="tel:<?php echo $this->_var['data']['kdy_telephone']; ?>" class="cart_change_btn">联系配送员</a> <br>
        <?php endif; ?>
        <?php if ($this->_var['data']['status'] == 3): ?>
       
         <?php if ($this->_var['data']['fenqi'] && $this->_var['data']['isdz'] == 0): ?>
        <a href="/index.php?m=koudai_order&a=duizhang&order_id=<?php echo $this->_var['data']['order_id']; ?>" class="cart_change_btn">去对账</a> <br>
        <?php endif; ?>
        <?php endif; ?>
      </div>
     
     
     
     
  
  <?php echo $this->fetch('footer.html'); ?> </div>
</body>
</html>